import Vue from 'vue'

export default {
  /**
   * 添加家族病史
   *
   * @param {*} [params={}]
   * @param {*} [config={}]
   * @returns
   */
  async addFamilyMedicalHistory(params = {}, config = {}) {
    let result = await Vue.http.post('/MedicalRecordFamilyMedicalHistory/AddFamilyMedicalHistory', params, config);
    return result;
  },
  /**
   * 通过编号获取家族病史
   *
   * @param {*} [params={}]
   * @param {*} [config={}]
   * @returns
   */
  async getFamilyMedicalHistoryByID(params = {}, config = {}) {
    config.params = params;
    let result = await Vue.http.get('/MedicalRecordFamilyMedicalHistory/GetFamilyMedicalHistoryByID', config);
    return result;
  },
  /**
   * 通过用户编号获取家族病史
   *
   * @param {*} [params={}]
   * @param {*} [config={}]
   * @returns
   */
  async getFamilyMedicalHistoryListByUserID(params = {}, config = {}) {
    config.params = params;
    let result = await Vue.http.get('/MedicalRecordFamilyMedicalHistory/GetFamilyMedicalHistoryListByUserID', config);
    return result;
  },
  /**
   * 更新家族病史
   *
   * @param {*} [params={}]
   * @param {*} [config={}]
   * @returns
   */
  async updateFamilyMedicalHistory(params = {}, config = {}) {
    let result = await Vue.http.put('/MedicalRecordFamilyMedicalHistory/UpdateFamilyMedicalHistory', params, config);
    return result;
  }
}
